Skip to content

Conversation

@NatLeung96
Copy link
Collaborator

This branch fixes the bug with the readback widget where it appears in the wrong place when rotated -90 degrees. The rotation of the actionbutton widget has also been changed to match the rotation behaviour of the label and readback widgets.

NatLeung96 and others added 5 commits May 16, 2025 14:14
* Removed references to diamondTheme and implemented useTheme hook

* Updated snapshots

* Added theme prop to embeddedDisplay widget

* Renamed diamondTheme to phoebusTheme

* Renamed exported theme to phoebusTheme

* Use phoebusTheme as default instead of the MUI default
Copy link
Collaborator

@abigailalexander abigailalexander left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All works fine, just one suggestion regarding moving the rotation calculation into a separate function that can be reused elsewhere.

NatLeung96 and others added 4 commits May 22, 2025 09:27
* Fixed widget rotation

* Updated border styling to match phoebus and added rounded corners

* Corrected offsets for 90 and -90 deg rotations

* Generalise use of themes (#117)

* Removed references to diamondTheme and implemented useTheme hook

* Updated snapshots

* Added theme prop to embeddedDisplay widget

* Renamed diamondTheme to phoebusTheme

* Renamed exported theme to phoebusTheme

* Use phoebusTheme as default instead of the MUI default

* Updated snapshots
Copy link
Collaborator

@abigailalexander abigailalexander left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, thanks!

@NatLeung96 NatLeung96 merged commit 61d4317 into 80-update-widgets-to-use-mui-base May 22, 2025
2 checks passed
@NatLeung96 NatLeung96 deleted the update-rotation-of-actionbutton-and-readback branch May 22, 2025 10:24
NatLeung96 added a commit that referenced this pull request May 22, 2025
* Updated the rotation for readback widget

* Updated rotation for actionbutton

* Removed commented out props

* Generalise use of themes (#117)

* Removed references to diamondTheme and implemented useTheme hook

* Updated snapshots

* Added theme prop to embeddedDisplay widget

* Renamed diamondTheme to phoebusTheme

* Renamed exported theme to phoebusTheme

* Use phoebusTheme as default instead of the MUI default

* Updated snapshot

* Update label borders and rotation (#119)

* Fixed widget rotation

* Updated border styling to match phoebus and added rounded corners

* Corrected offsets for 90 and -90 deg rotations

* Generalise use of themes (#117)

* Removed references to diamondTheme and implemented useTheme hook

* Updated snapshots

* Added theme prop to embeddedDisplay widget

* Renamed diamondTheme to phoebusTheme

* Renamed exported theme to phoebusTheme

* Use phoebusTheme as default instead of the MUI default

* Updated snapshots

* Added a function for calculating width, height, and transform for rotated widgets

* Implemented the new calculateRotationTransform function
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants